<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
<head>
	<meta charset="UTF-8">
	<title>优惠券详情</title>
	<script th:src="@{/layui/layui.js}" type="text/javascript"></script>
	<link th:href="@{/layui/css/layui.css}" rel="stylesheet" />
</head>
		<style>
			#coupon{
				width: 850px;
				height: 300px;
			}
		</style>
	<body>
		<div style="height: auto;width:auto;margin-left:20px;margin-top: 20px">
			<table class="" id="coupon" border="1" style="border: 1px solid #B9BBBE;">
				<tr style="background-color: #f2f6fc;">
					<td  align="center" valign="middle"style="width: 16.6%">名称</td>
					<td  align="center" valign="middle"style="width: 16.6%;">介绍</td>
					<td  align="center" valign="middle"style="width: 16.6%">标签</td>
					<td  align="center" valign="middle"style="width: 16.6%">优惠券类型</td>
					<td  align="center" valign="middle"style="width: 16.6%">最低消费</td>
					<td  align="center" valign="middle"style="width: 16.6%">优惠券面值</td>
				</tr>
				<tr>
					<td  align="center" valign="middle" th:text="${c.name}" style="height: 80px"></td>
					<td  align="center" valign="middle" th:text="${c.introduce}" style="height: 80px"></td>
					<td  align="center" valign="middle" th:text="${c.label}" style="height: 80px"></td>
					<td  align="center" valign="middle" th:text="${c.type}" style="height: 80px"></td>
					<td  align="center" valign="middle" th:text="${c.minimumConsumption}" style="height: 80px"></td>
					<td  align="center" valign="middle" th:text="${c.fullMinus}" style="height: 80px"></td>
				</tr>
				<tr style="background-color: #f2f6fc;">
					<td  align="center" valign="middle"style="width: 16.6%">每人限领</td>
					<td  align="center" valign="middle"style="width: 16.6%">当前状态</td>
					<td  align="center" valign="middle"style="width: 16.6%">商品范围</td>
					<td  align="center" valign="middle"style="width: 16.6%">有效期</td>
					<td  align="center" valign="middle"style="width: 16.6%">优惠兑换码</td>
					<td  align="center" valign="middle"style="width: 16.6%">发行数量</td>
				</tr>
				<tr>
					<td  align="center" valign="middle" th:text="${c.lim}" style="height: 80px"></td>
					<td  align="center" valign="middle" th:text="${c.state}" style="height: 80px"></td>
					<td  align="center" valign="middle" th:text="${c.useRange}" style="height: 80px"></td>
					<td  align="center" valign="middle" th:text="${c.timeType}" style="height: 80px"></td>
					<td  align="center" valign="middle" th:text="${c.exchangeCode}" style="height: 80px"></td>
					<td  align="center" valign="middle" th:text="${c.number}" style="height: 80px"	></td>
				</tr>
			</table>
		</div>
		<div style="margin-left: 30px">
			<table id="couponUser" lay-filter="couponUser"></table>
		</div>

		<script>
			var $;
			layui.use(['layer','table','jquery'],function () {
				var layer = layui.layer, table = layui.table;
				$ = layui.jquery;

				table.render({
					elem:'#couponUser',
					url:'/system/cuc/find',
					width:800,
					page:true,
					cols:[
							[
								{field:'id',title:'用户优惠券Id'},
								{field:'userId',title:'用户Id'},
								{field:'createTime',title:'领取时间'},
								{field:'state',title:'使用状态'},
								{field:'orderId',title:'订单Id'},
								{field:'useTime',title:'使用时间'},
							]
					]
				})
			})
		</script>
	</body>
</html>
